import request from '@/utils/request'

// 查询入社审批列表
export function listApprove(query) {
  return request({
    url: '/system/approve/list',
    method: 'get',
    params: query
  })
}

// 查询入社审批详细
export function getApprove(approveId) {
  return request({
    url: '/system/approve/' + approveId,
    method: 'get'
  })
}

// 新增入社审批
export function addApprove(data) {
  return request({
    url: '/system/approve',
    method: 'post',
    data: data
  })
}

// 入社审批通过
export function approveYes(data) {
  return request({
    url: '/system/approve/yes',
    method: 'post',
    data: data
  })
}

// 入社批量审批
export function approveBatch(approveId) {
  return request({
    url: '/system/approve/batchyes/' + approveId,
    method: 'get'
  })
}

// 修改入社审批
export function updateApprove(data) {
  return request({
    url: '/system/approve',
    method: 'put',
    data: data
  })
}

// 删除入社审批
export function delApprove(approveId) {
  return request({
    url: '/system/approve/' + approveId,
    method: 'delete'
  })
}

// 导出入社审批
export function exportApprove(query) {
  return request({
    url: '/system/approve/export',
    method: 'get',
    params: query
  })
}